
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html">
<ui:composition>
	<h:head>
		<!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
		<script src="https://code.jquery.com/jquery.js"></script>
		<!-- Include all compiled plugins (below), or include individual files as needed -->
		<h:outputScript library="js" name="bootstrap.min.js" />
		<h1 align="center">
			<h:outputText value="Domótica - ML SQ" class="label label-primary" />
		</h1>
	</h:head>
	<h:body>
		<h:outputStylesheet library="css" name="bootstrap.min.css" />
		<h:form><div class="container-fluid">
				<h:panelGrid id="panel" columns="2" border="1" cellpadding="5" cellspacing="5" style="margin: 0 auto;" >
					<f:facet name="header">
						<h:outputText value="#{messages.SIGN_IN_MESSAGE}" class="navbar-text" />
					</f:facet>

					<h:outputLabel for="username" value="#{messages.USERNAME}" class="navbar-text" />

					<h:inputText id="username" value="#{loginBean.username}" size="15" requiredMessage="Obrigatório" required="true" class="form-control">
						<f:validateLength minimum="2" />
					</h:inputText>

					<h:outputLabel for="password" value="#{messages.PASSWORD}" class="navbar-text" />
					<h:inputSecret id="password" value="#{loginBean.password}" size="15" requiredMessage="Obrigatório" required="true" class="form-control">
						<f:validateLength minimum="2" />
					</h:inputSecret>

					<f:facet name="footer">
						<h:panelGroup style="display:block; text-align:center">
							<h:commandButton id="submit" value="#{messages.SUBMIT}" action="#{loginBean.login}" class="btn btn-default navbar-bt" />
						</h:panelGroup>
					</f:facet>
				</h:panelGrid>
			</div>

			

		</h:form>

	</h:body>
</ui:composition>
</html>